<?php

function bb_register() {
	$dt = mysql_fetch_array(mysql_query(
		"SELECT kd_reg_bb 
		FROM t_bb
		WHERE tanggal LIKE '%".date("Y")."%' 
		ORDER BY kd_reg_bb DESC limit 1"));
	$arr = explode('/',$dt[0]);
	
	return "BB/".str_repeat("0", 4 - strlen($arr[1]+1)).($arr[1]+1)."/".date("Y");
}

?>
